package io.gitee.chearnee.fw.datasecurity.sd.extension.ruleimpl;

import io.gitee.chearnee.fw.common.utils.ConstStringPool;
import io.gitee.chearnee.fw.datasecurity.core.enums.NumEnum;
import io.gitee.chearnee.fw.datasecurity.core.handler.desensitization.SDRuleHandler;
import io.gitee.chearnee.fw.datasecurity.sd.extension.annotation.SDDepositBankNoField;

/**
 * @author cn
 * @version 1.0
 * @description
 * @date 11/22/2022 11:18 AM
 */
public class DepositBankNoRuleHandler implements SDRuleHandler<SDDepositBankNoField> {
    @Override
    public Class<SDDepositBankNoField> getAnnotationType() {
        return SDDepositBankNoField.class;
    }

    @Override
    public String masking(SDDepositBankNoField sdIdCardField, String object) {
        return baseMasking(NumEnum.TWO.getValue(), NumEnum.NAN.getValue(), ConstStringPool.MASK_STRING, object);
    }
}
